package adapterPattern;


/**
 * @program: course
 * @author: lsn
 * @create: 2024-04-13 17:31
 * @description: 电视机使用两相插座
 */
public class TV implements TwoElectricOutlet{
    String name;

    public TV() {
        name = "长江电视机";
    }

    public TV(String name) {
        this.name = name;
    }

    @Override
    public void connectElectricCurrent() {
        turnOn();
    }

    public void turnOn(){
        System.out.println(name + "开始播放节目。");
    }
}

